package com.javasm.finance.dao;

import com.javasm.finance.entity.User;
import com.javasm.finance.entity.UserMenu;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.List;

public interface UserDao {
    User findLoginUser(String userName,String userPwd) throws SQLException;
    List<String> findLoginUserMenuUrl(Integer userId) throws SQLException;
    List<User> findUser(Integer page, Integer pageSize, User user) throws SQLException;
    long findTotalNum(User user) throws SQLException;
    int addUser(User user) throws SQLException;
    User findByUid(Integer userId) throws SQLException;
    int editUser(User user) throws SQLException;
    int deleteUser(Integer userId, Connection conn) throws SQLException;
    List<UserMenu> findUserMenu(Integer userId) throws SQLException;
    int deleteUserMenu(Integer userId, Connection conn) throws SQLException;
    int editLoginTime(Integer userId) throws SQLException;
}
